package service;

import java.util.List;

import dao.SupplierDao;
import entity.Supplier;
import util.PageTools;

public class SupplierService {
private SupplierDao supplierDao=new SupplierDao();
	
	public boolean insertSupplier(Supplier supplier) {
		return supplierDao.insertSupplier(supplier);
	}
	public boolean deleteSupplierBySname(String sname) {
		return supplierDao.deleteSupplierBySname(sname);
	}
	public List<Supplier> showSupplier(){
		return supplierDao.selectSupplier();
	}
	public int counts() {
		return supplierDao.counts();
	}
	public List<Supplier> showSupplierByPage(PageTools pt){
		return supplierDao.selectSupplierByPage(pt);
	}
	public Supplier showSupplierBySname(String sname) {
		return supplierDao.selectSupplierBySname(sname);
	}
	public boolean updateSupplier(Supplier supplier) {
		return supplierDao.updateSupplier(supplier);
	}


}
